import { createRouter, createWebHashHistory } from 'vue-router'
//完善路由页代码
import { constantRoutes } from './router'

const router = createRouter({
  //路由配置
  history: createWebHashHistory(),
  routes: constantRoutes,
  scrollBehavior() {
    return {
      top: 0,
      left: 0,
      behavior: 'smooth',
    }
  },
})

export default router
